package com.qst.crop.service;

import com.github.pagehelper.PageInfo;
import com.qst.crop.entity.Export;
import com.qst.crop.entity.Order;
import com.qst.crop.entity.User;

import java.util.List;

/**
 * @author spengda
 * @date 2024/3/713:37
 */
public interface UserService {
    List<User> selectAll();

    void add(User user);

    void update(User user);

    void delete(String userName);

    User selectByUserName(String userName);

    PageInfo<User> findPage(Integer pageNum);

    PageInfo<User> findPage(User user, Integer pageNum, Integer pageSize);

    int loginUpdateByUsername(User user);

    PageInfo<User> findAll(Integer pageNum);

    String getRoleByName(String username);


    User loginSelectByUsername(String username);

    int updatePassword(String username,String pwd);

    String getRealName(String username);

    String getRole(String username);

    Export searchExpert(String username);

    /**
     * 初始化当前用户信息
     * @param username
     * @return
     */
    User initUser(String username);


}
